package com.xywh.micro_warehousing.di.module;

import com.jess.arms.di.scope.FragmentScope;

import dagger.Module;
import dagger.Provides;

import com.xywh.micro_warehousing.mvp.contract.Tab4Contract;
import com.xywh.micro_warehousing.mvp.model.Tab4Model;


@Module
public class Tab4Module {
    private Tab4Contract.View view;

    /**
     * 构建Tab4Module时,将View的实现类传进来,这样就可以提供View的实现类给presenter
     *
     * @param view
     */
    public Tab4Module(Tab4Contract.View view) {
        this.view = view;
    }

    @FragmentScope
    @Provides
    Tab4Contract.View provideTab4View() {
        return this.view;
    }

    @FragmentScope
    @Provides
    Tab4Contract.Model provideTab4Model(Tab4Model model) {
        return model;
    }
}